home *** CD-ROM | disk | FTP | other *** search
/ Kit PC World De Ampliacion De Windows 95 / Kit PC World de ampliacion de Windows 95.iso / internet / sweeper / samples / olecon~1 / wizards / automain.frm < prev    next >
Text File  |  1995-11-22  |  7KB  |  231 lines

  1. VERSION 4.00
  2. Begin VB.Form frmMainWizard 
  3.    BorderStyle     =   3  'Fixed Dialog
  4.    Caption         =   "Create Automation Server"
  5.    ClientHeight    =   4050
  6.    ClientLeft      =   2460
  7.    ClientTop       =   2910
  8.    ClientWidth     =   6810
  9.    Height          =   4455
  10.    Left            =   2400
  11.    LinkTopic       =   "Form1"
  12.    MaxButton       =   0   'False
  13.    MinButton       =   0   'False
  14.    ScaleHeight     =   4050
  15.    ScaleWidth      =   6810
  16.    ShowInTaskbar   =   0   'False
  17.    Top             =   2565
  18.    Width           =   6930
  19.    Begin VB.CheckBox chkSatellite 
  20.       Caption         =   "Use Satellite DLL &Localization"
  21.       Height          =   375
  22.       Left            =   1560
  23.       TabIndex        =   6
  24.       Top             =   2400
  25.       Visible         =   0   'False
  26.       Width           =   3015
  27.    End
  28.    Begin VB.CheckBox chkLoser 
  29.       Caption         =   "I need to be used with a &retarded system and must not have LFN's"
  30.       Height          =   375
  31.       Left            =   1560
  32.       TabIndex        =   5
  33.       Top             =   2760
  34.       Visible         =   0   'False
  35.       Width           =   5055
  36.    End
  37.    Begin VB.TextBox txtUseful 
  38.       Height          =   375
  39.       Left            =   1440
  40.       TabIndex        =   4
  41.       Text            =   "Text1"
  42.       Top             =   1440
  43.       Visible         =   0   'False
  44.       Width           =   5175
  45.    End
  46.    Begin VB.CommandButton cmdNext 
  47.       Caption         =   "&Next >"
  48.       Default         =   -1  'True
  49.       Height          =   375
  50.       Left            =   4320
  51.       TabIndex        =   1
  52.       Top             =   3555
  53.       Width           =   1095
  54.    End
  55.    Begin VB.CommandButton btnFinishCancel 
  56.       Cancel          =   -1  'True
  57.       Caption         =   "Cancel"
  58.       Height          =   375
  59.       Left            =   5520
  60.       TabIndex        =   2
  61.       Top             =   3555
  62.       Width           =   1095
  63.    End
  64.    Begin VB.CommandButton cmdBack 
  65.       Caption         =   "< &Back"
  66.       Enabled         =   0   'False
  67.       Height          =   375
  68.       Left            =   3240
  69.       TabIndex        =   0
  70.       Top             =   3555
  71.       Width           =   1095
  72.    End
  73.    Begin VB.Label lblMessage 
  74.       Caption         =   "Welcome to the Automation Server Creation Wizard. Please Click ""Next"" to begin."
  75.       Height          =   975
  76.       Left            =   1440
  77.       TabIndex        =   3
  78.       Top             =   240
  79.       Width           =   5175
  80.    End
  81.    Begin VB.Line Line2 
  82.       BorderColor     =   &H00FFFFFF&
  83.       X1              =   120
  84.       X2              =   6600
  85.       Y1              =   3375
  86.       Y2              =   3375
  87.    End
  88.    Begin VB.Line Line1 
  89.       BorderColor     =   &H00808080&
  90.       X1              =   120
  91.       X2              =   6600
  92.       Y1              =   3360
  93.       Y2              =   3360
  94.    End
  95. End
  96. Attribute VB_Name = "frmMainWizard"
  97. Attribute VB_Creatable = False
  98. Attribute VB_Exposed = False
  99.  
  100. Private Sub btnFinishCancel_Click()
  101.  
  102.     If iStage = STAGE_FINISHING Then
  103.         Unload Me
  104.     Else
  105.         TerminateApplication
  106.     End If
  107.     
  108. End Sub
  109.  
  110.  
  111. Private Sub cbosubclass_Click()
  112.  
  113.     g_szSubClassName = cbosubclass.List(cbosubclass.ListIndex)
  114.  
  115. End Sub
  116.  
  117. Private Sub chkloser_Click()
  118.  
  119.     g_fLoser = chkloser.Value
  120.     
  121. End Sub
  122.  
  123. Private Sub chkSatellite_Click()
  124.  
  125.     g_fSatellite = chkSatellite.Value
  126.     
  127. End Sub
  128.  
  129. Private Sub cmdBack_Click()
  130.  
  131.     iStage = iStage - 1
  132.     If iStage = STAGE_SUBCLASS And chkSubClass.Value <> vbChecked Then iStage = iStage - 1
  133.     m_SwitchPage
  134.     
  135. End Sub
  136.  
  137. Private Sub cmdNext_Click()
  138.  
  139.     If iStage = STAGE_CONTROLNAME And chkSubClass.Value <> vbChecked Then iStage = iStage + 1
  140.     iStage = iStage + 1
  141.     m_SwitchPage
  142.     
  143. End Sub
  144.  
  145. Private Sub Form_Load()
  146.  
  147.     Top = (Screen.Height - Height) / 3
  148.     Left = (Screen.Width - Width) / 2
  149.     
  150. End Sub
  151.  
  152.  
  153. Private Sub m_SwitchPage()
  154.     
  155.     Select Case iStage
  156.         Case STAGE_WELCOME
  157.             lblmessage = "Welcome to the Control Creation Wizard. Please Click ""Next"" to begin."
  158.             chkSatellite.Visible = False
  159.             chkSubClass.Visible = False
  160.             cbosubclass.Visible = False
  161.             txtuseful.Visible = False
  162.             chkSubClass.Visible = False
  163.             chkloser.Visible = False
  164.             cmdBack.Enabled = False
  165.             cmdNext.Enabled = True
  166.             
  167.         Case STAGE_CONTROLNAME
  168.             lblmessage = "Please Enter a Name for your Control."
  169.             chkSatellite.Visible = True
  170.             txtuseful.Text = szControlName
  171.             chkSubClass.Visible = True
  172.             cbosubclass.Visible = False
  173.             chkloser.Visible = True
  174.             txtuseful.Visible = True
  175.             cmdBack.Enabled = True
  176.             cmdNext.Enabled = True
  177.             txtuseful.SetFocus
  178.  
  179.         Case STAGE_SUBCLASS
  180.             lblmessage = "Please Choose a control class on which to base your control."
  181.             chkSatellite.Visible = False
  182.             chkSubClass.Visible = False
  183.             cbosubclass.Visible = True
  184.             cbosubclass.SetFocus
  185.             chkloser.Visible = False
  186.             txtuseful.Visible = False
  187.             cmdBack.Enabled = True
  188.             cmdNext.Enabled = True
  189.  
  190.         Case STAGE_CONTROLDIR
  191.             lblmessage = "Please Enter the location you'd like the source files to go."
  192.             chkSatellite.Visible = False
  193.             chkSubClass.Visible = False
  194.             cbosubclass.Visible = False
  195.             txtuseful.Text = szFinalDir
  196.             txtuseful.Visible = True
  197.             cmdBack.Enabled = True
  198.             chkloser.Visible = False
  199.             cmdNext.Enabled = True
  200.             txtuseful.SetFocus
  201.  
  202.         Case STAGE_FINISHING
  203.             lblmessage = "Thank you.  Please Choose Finish to Complete the Creation of your control."
  204.             chkSatellite.Visible = False
  205.             chkSubClass.Visible = False
  206.             cbosubclass.Visible = False
  207.             txtuseful.Visible = False
  208.             chkloser.Visible = False
  209.             cmdBack.Enabled = True
  210.             cmdNext.Enabled = False
  211.             btnFinishCancel.Caption = "&Finish"
  212.             btnFinishCancel.SetFocus
  213.             
  214.     End Select
  215.                 
  216.             
  217.             
  218. End Sub
  219.  
  220. Private Sub txtuseful_Change()
  221.  
  222.     Select Case iStage
  223.         Case STAGE_CONTROLNAME
  224.             szControlName = txtuseful.Text
  225.         Case STAGE_CONTROLDIR
  226.             szFinalDir = txtuseful.Text
  227.     End Select
  228.         
  229. End Sub
  230.  
  231.